/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package co.com.claro.administracionSolicitudes.entity;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;

import javax.validation.constraints.Size;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author Mike
 */
@Entity
@Table(name = "PARAMETROS_PASSWORD")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "ParametrosPassword.findAll", query = "SELECT p FROM ParametrosPassword p"),
    @NamedQuery(name = "ParametrosPassword.findByMinCaracteres", query = "SELECT p FROM ParametrosPassword p WHERE p.minCaracteres = :minCaracteres"),
    @NamedQuery(name = "ParametrosPassword.findByMinMayusculas", query = "SELECT p FROM ParametrosPassword p WHERE p.minMayusculas = :minMayusculas"),
    @NamedQuery(name = "ParametrosPassword.findByMinMinusculas", query = "SELECT p FROM ParametrosPassword p WHERE p.minMinusculas = :minMinusculas"),
    @NamedQuery(name = "ParametrosPassword.findByMinNumeros", query = "SELECT p FROM ParametrosPassword p WHERE p.minNumeros = :minNumeros"),
    @NamedQuery(name = "ParametrosPassword.findByIdParamPassword", query = "SELECT p FROM ParametrosPassword p WHERE p.idParamPassword = :idParamPassword")})
public class ParametrosPassword extends EntidadBase implements Serializable {
    @Basic(optional = false)
    @Size(min = 1, max = 50)
    @Column(name = "DEFAULT_PASSWORD")
    private String defaultPassword;
    private static final long serialVersionUID = 1L;
    @Basic(optional = false)
    @Column(name = "MIN_CARACTERES")
    private short minCaracteres;
    @Basic(optional = false)
    @Column(name = "MIN_MAYUSCULAS")
    private short minMayusculas;
    @Basic(optional = false)
    @Column(name = "MIN_MINUSCULAS")
    private short minMinusculas;
    @Basic(optional = false)
    @Column(name = "MIN_NUMEROS")
    private short minNumeros;
    @Id
    @Basic(optional = false)
    @Column(name = "ID_PARAM_PASSWORD")
    private Short idParamPassword;

    public ParametrosPassword() {
    }

    public ParametrosPassword(Short idParamPassword) {
        this.idParamPassword = idParamPassword;
    }

    public ParametrosPassword(Short idParamPassword, short minCaracteres, short minMayusculas, short minMinusculas, short minNumeros) {
        this.idParamPassword = idParamPassword;
        this.minCaracteres = minCaracteres;
        this.minMayusculas = minMayusculas;
        this.minMinusculas = minMinusculas;
        this.minNumeros = minNumeros;
    }

    public short getMinCaracteres() {
        return minCaracteres;
    }

    public void setMinCaracteres(short minCaracteres) {
        this.minCaracteres = minCaracteres;
    }

    public short getMinMayusculas() {
        return minMayusculas;
    }

    public void setMinMayusculas(short minMayusculas) {
        this.minMayusculas = minMayusculas;
    }

    public short getMinMinusculas() {
        return minMinusculas;
    }

    public void setMinMinusculas(short minMinusculas) {
        this.minMinusculas = minMinusculas;
    }

    public short getMinNumeros() {
        return minNumeros;
    }

    public void setMinNumeros(short minNumeros) {
        this.minNumeros = minNumeros;
    }

    public Short getIdParamPassword() {
        return idParamPassword;
    }

    public void setIdParamPassword(Short idParamPassword) {
        this.idParamPassword = idParamPassword;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (idParamPassword != null ? idParamPassword.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof ParametrosPassword)) {
            return false;
        }
        ParametrosPassword other = (ParametrosPassword) object;
        if ((this.idParamPassword == null && other.idParamPassword != null) || (this.idParamPassword != null && !this.idParamPassword.equals(other.idParamPassword))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "co.com.claro.adminSolicitudes.entity.ParametrosPassword[ idParamPassword=" + idParamPassword + " ]";
    }

    public String getDefaultPassword() {
        return defaultPassword;
    }

    public void setDefaultPassword(String defaultPassword) {
        this.defaultPassword = defaultPassword;
    }

    @Override
    public String obtenerNombreClase() {
        return "ParametrosPassword";
    }
    
}
